package com.frogs.ucenter.dao.ibatis;

import java.util.Map;

import com.frogs.framework.base.dao.ibatis.BaseDaoIbatis;
import com.frogs.framework.util.PageList;
import com.frogs.ucenter.dao.UserDrugDao;
import com.frogs.ucenter.entity.UserDrug;
import com.ibatis.sqlmap.client.SqlMapClient;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.beans.factory.annotation.Required;
import org.springframework.stereotype.Repository;

@Repository("userDrugDao")
public class UserDrugDaoImpl extends BaseDaoIbatis<UserDrug> implements UserDrugDao {

    public UserDrugDaoImpl() {
        super();
        setNameSpace( "user_drug" );
    }

    @Required
    @Autowired
    public void setSqlMapClientAutowired(SqlMapClient sqlMapClient) {
        super.setSqlMapClient( sqlMapClient );
    }

	@Override
	public PageList<Map<String, Object>> selectByMapWithMap(
			Map<String, Object> params, int pageNo, int pageSize) {
		return (PageList<Map<String, Object>>) queryforPageList(getNameSpace() + ".selectByMapForMap", params, pageNo, pageSize, true);
	}
}